package com.example.hal;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import java.util.logging.Logger;

import javax.servlet.http.*;

import com.example.hal.model.Departement;
import com.example.hal.model.Domaine;
import com.example.hal.model.Offre;
import com.example.hal.model.Utilisateur;
import com.example.hal.server.DomaineController;
import com.example.hal.server.OffreController;
import com.example.hal.server.RestletDispatch;
import com.example.hal.server.UtilisateurController;
import com.example.hal.server.UtilisateurFacebookController;
import com.example.hal.server.DepartementController;

@SuppressWarnings("serial")
public class HalRestServlet extends HttpServlet {
	public void doGet(HttpServletRequest req, HttpServletResponse resp)
			throws IOException {
		/*DomaineController oc=new DomaineController();
		Domaine d=new Domaine();
		d.setNom("Livraison");
		oc.create(d);
		/*DepartementController vc=new DepartementController();
		
		List<Departement> vl=new ArrayList<Departement>();
		Departement v;
		v=new Departement("	Ain	","	01	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Aisne	","	02	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Allier	","	03	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Alpes-de-Haute-Provence	","	04	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Hautes-Alpes	","	05	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Alpes-Maritimes	","	06	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Ardeche	","	07	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Ardennes	","	08	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Ariege	","	09	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Aube	","	10	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Aude	","	11	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Aveyron	","	12	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Bouches-du-Rhone	","	13	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Calvados	","	14	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Cantal	","	15	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Charente	","	16	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Charente-Maritime	","	17	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Cher	","	18	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Correze	","	19	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Corse	","	20	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Cote-d Or	","	21	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Cotes-d Armor	","	22	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Creuse	","	23	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Dordogne	","	24	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Doubs	","	25	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Drome	","	26	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Eure	","	27	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Eure-et-Loir	","	28	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Finistere	","	29	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Gard	","	30	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Garonne	","	31	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Gers	","	32	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Gironde	","	33	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Herault	","	34	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Ille-et-Vilaine	","	35	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Indre	","	36	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Indre-et-Loire	","	37	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Isere	","	38	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Jura	","	39	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Landes	","	40	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Loir-et-Cher	","	41	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Loire	","	42	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Loire	","	43	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Loire-Atlantique	","	44	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Loiret	","	45	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Lot	","	46	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Lot-et-Garonne	","	47	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Lozere	","	48	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Maine-et-Loire	","	49	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Manche	","	50	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Marne	","	51	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Marne	","	52	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Mayenne	","	53	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Meurthe-et-Moselle	","	54	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Meuse	","	55	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Morbihan	","	56	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Moselle	","	57	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Nievre	","	58	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Nord	","	59	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Oise	","	60	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Orne	","	61	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Pas-de-Calais	","	62	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Puy-de-Dome	","	63	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Pyrenees-Atlantiques	","	64	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Hautes-Pyrenees	","	65	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Pyrenees Orientales	","	66	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Bas-Rhin	","	67	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haut-Rhin	","	68	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Rhone	","	69	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Saone	","	70	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Saone-et-Loire	","	71	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Sarthe	","	72	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Savoie	","	73	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Savoie	","	74	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Paris (la ville)	","	75	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Seine-Maritime	","	76	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Seine-et-Marne	","	77	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Yvelynes	","	78	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Deux Sevres	","	79	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Somme	","	80	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Tarn	","	81	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Tarn-et-Garonne	","	82	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Var	","	83	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Vaucluse	","	84	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Vendee	","	85	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Vienne	","	86	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Haute-Vienne	","	87	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Vosges	","	88	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Yonne	","	89	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Territoire de Belfort	","	90	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Essonne	","	91	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Hauts-de-Seine	","	92	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Seine-Saint-Denis	","	93	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Val de Marne	","	94	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Val d Oise	","	95	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Guadeloupe	","	971	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Martinique	","	972	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Guyane	","	973	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Reunion	","	974	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	St-Pierre-et-Miquelon	","	975	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Mayotte	","	976	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Wallis et Futuna	","	986	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Polynesie Francaise	","	987	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		v=new Departement("	Nouvelle-Caledonie	","	988	"); v.setNom(v.getNom().trim()); v.setCodePostal(v.getCodePostal().trim()); vc.create(v);	
		*/resp.setContentType("text/plain");
		resp.getWriter().println("Hello, world");
	}
}
